package process.ast;

import java.util.Vector;

import process.visitor.Visitor;

public class Process implements Node{
	String id;
	Vector<Workflow> workflows = new Vector<Workflow>();

	public Process(String id) {
		super();
		this.id = id;
	}

	public void addWorkflow(Workflow workflow) {
		if (workflow != null) {
			workflows.add(workflow);
		}
	}

	public Vector<Workflow> getWorkflows() {
		return workflows;
	}

//	public String toStringProcess() {
//		String out = this.getId();
//		for (Workflow wf : workflows) {
//			out += "\n" + wf.toWorkflowString();
//		}
//		return out;
//	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public void accept(Visitor visitor) {
		visitor.visit(this);
	}

}
